// 此处存放登录有关的接口请求

import request from '@/utils/request'

// 1.获取图形验证码
export const getPicCode = () => {
  return request.get('/captcha/image')
}

// 2获取短信验证码
export const getMsgCode = (captchaCode, captchaKey, mobile) => {
  return request.post('/captcha/sendSmsCaptcha', {
      captchaCode,
      captchaKey,
      mobile
  })
}

// 3登录接口
export const codeLogin = (mobile, smsCode) => {
  return request.post('/passport/login', {
      isParty: false,
      partyData: {},
      mobile,
      smsCode
  })
}
